import re
import requests
from plugin.dk.Image import Image

image = Image()


def downloadImage(os):
    """
    下载image
    :param os:
    :return:
    """
    if re.search(r':', os) is None:

        return image.pull(os + ':latest')
    else:
        return image.pull(os)
    return None

def downloadDockerFile(url):
    """
    下载dockerFile文件
    :param url: 完整的url
    :return: string
    """
    result=requests.get(url)
    print(result.content)